package com.heima.leadnews.wemedia.controller;


import com.heima.leadnews.wemedia.service.WmUserService;
import com.heima.model.common.dtos.ResponseResult;
import com.heima.model.wemedia.dto.WmUserLoginDTO;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMapping;

import org.springframework.web.bind.annotation.RestController;

import java.io.PipedReader;

/**
 * <p>
 * 自媒体用户信息表 前端控制器
 * </p>
 *
 * @author author
 * @since 2023-06-03
 */
@RestController
@RequestMapping("/login")
public class WmUserLoginController {

    @Autowired
    private WmUserService wmUserService;

    /**
     * 登录
     */
    @PostMapping("/in")
    public ResponseResult login(@RequestBody WmUserLoginDTO dto){
        return wmUserService.login(dto);
    }
}
